import { useNavigate } from 'react-router-dom';
import React from 'react';

const  withNavigate = (Component) => {
  return (props={}) => <Component {...props} navigate={useNavigate()} />;
}
export default withNavigate
